<template>
  <div>
    <a-card :bordered="false">
      <div class="table-page-search-wrapper">
        <a-form layout="inline">
          <a-row :gutter="48">
            <a-col :md="8" :sm="8">
              <a-form-item label="学院">
                <a-input placeholder="请输入学院" v-model="queryParam.institute" />
              </a-form-item>
            </a-col>
            <a-col :md="8" :sm="8">
              <a-form-item label="专业班级">
                <a-input placeholder="请输入专业班级" v-model="queryParam.major" />
              </a-form-item>
            </a-col>
            <a-col :md="8" :sm="8">
              <a-form-item label="导员名称">
                <a-input placeholder="请输入导员名称" v-model="queryParam.assistantName" />
              </a-form-item>
            </a-col>
            <a-col :md="8" :sm="24">
              <a-button @click="() => {this.queryPage()}" type="primary">查询</a-button>
              <a-button @click="() =>{ queryParam = {}}" style="margin-left: 8px">重置</a-button>
            </a-col>
          </a-row>
        </a-form>
      </div>
      <v-table
        :table-column="columns"
        :data="loadData"
        :rowKey="record => record.id"
        bordered
        ref="table"
        style="margin-top:8px"
      >
      </v-table>
    </a-card>
  </div>
</template>

<script>
import { TableMixin } from '@/mixins/TableMixin'
import { dataList } from '@api/wfuSign/wfuSign'

export default {
  components: {},
  mixins: [TableMixin],
  name: 'notSignInReport',
  data () {
    return {
      columns: [
        {
          title: '学生姓名',
          dataIndex: 'userName'
        },
        {
          title: '学号',
          dataIndex: 'userCode'
        },
        {
          title: '学院',
          dataIndex: 'institute'
        },
        {
          title: '专业班级',
          dataIndex: 'major'
        },
        {
          title: '学生电话',
          dataIndex: 'mobile'
        },
        {
          title: '导员姓名',
          dataIndex: 'assistantName'
        },
        {
          title: '导员工号',
          dataIndex: 'assistantCode'
        },
        {
          title: '导员电话',
          dataIndex: 'assistantMobile'
        }
        /* {
          title: '操作',
          width: '80px',
          customRender: (text, record, index) => {
            return (
              <div>
                <a onClick={(e) => this.show(record)}
                >查看</a>
              </div>
            )
          }
        } */
      ],
      queryParam: {
        signType: 'wfu_sign_hd_out_no'
      },
      visible: true,
      confirmLoading: false,
      loadData: parameter => {
        return dataList(
          Object.assign(parameter, this.queryParam)
        ).then(res => {
          console.log(res)
          return res.data
        })
      }
    }
  },
  methods: {
    sign (val) {
      this.visible = true
      this.queryParam.signType = val
    },
    handleCancel () {
      this.visible = false
    }
  }
}
</script>

<style scoped>

</style>
